<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> 

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>		
		<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
		<link rel="shortcut icon" href="/resources/favicon.ico" type="image/x-icon"/>
		<link rel="stylesheet" type="text/css" href="/resources/styles.css">
		<title>Homegrown Cuisine - Admin</title>				
	</head>	
	<body background="">		
		<h1>Welcome Administrator</h1>

		<a href="/admin">Back</a>
		
		<div id="seasonDiv">
			<h2>Category</h2>
			<p>${message}</p>
			<form:form method="POST" modelAttribute="category" accept-charset="UTF-8">
				<table>
	        		<tr>
	            		<td>Name:</td>
	            		<td><form:input path="name"/></td> 
	        		</tr>
	        		<tr>
			            <td colspan="2">
			              <input type="submit" value="Save" />
			            </td>
			        </tr>
			        <c:forEach items="${categories}" var="category">					
						<tr>					
							<td>${category.name}</td>						
						</tr>		
					</c:forEach>			        
	        	</table>
			</form:form>
		</div>		
	</body>	
</html>